<template>
    <view>

        <a-drawer width="1200" v-model:visible="visible" class="custom-class" style="color: red"
            :title="`${flow?.serviceName}`" placement="right">
            <a-card>
                <a-row>
                    <a-col :span="12">
                        <a-input v-model:value="audit" placeholder="输入审计意见" />
                    </a-col>
                    <a-col :span="2">
                        
                    </a-col>
                    <a-col :span="4">
                        <a-button type="primary">通过</a-button>
                    </a-col>
                    <a-col :span="4">
                        <a-button type="danger">拒绝</a-button>
                    </a-col>
                </a-row>
                
            </a-card>

            <view v-if="flow.serviceType == '论文'">
                <PaperDesc :record="project"></PaperDesc>
            </view>
        </a-drawer>
        
    </view>
</template>
<script setup>
import PaperDesc from '../../project/paper/components/PaperDesc.vue';
import useApp from '@/hooks';
const { $ } = useApp();
const visible = ref(false);
const flow = ref(null)
const modal = ref(true)
const project = ref(null)
const audit = ref(null)
$.on('preview-flow', e => {
    console.log(e)
    flow.value = e;

    project.value = JSON.parse(e.flowParam);


    // if (e.currentNodeType == 'TASK') {
    //     visible.value = true;
    // }
})
</script>